﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using RM.Entities.Data;

namespace RM.Plumber
{
    class Program
    {
        static void Main(string[] args)
        {
            try
            {
                Console.WriteLine("You are about to flush the database away in air. Are you ready to go ? if so press 'Y' else press any other key");

                string userInput = Console.ReadLine();

                if (!string.IsNullOrEmpty(userInput) && userInput.Equals("Y"))
                {
                    DataManager dataManager = new DataManager();
                    dataManager.SetupDB();
                }
                else
                {
                    Console.WriteLine("Nothing happened to you database don't woryy..");
                }
            }
            catch (Exception ex)
            {

                Console.WriteLine("Something wrong happened the error reported is " + ex.Message);
            }
            finally
            {
                Console.WriteLine("You are DB is flushed into the air :(");
                Console.ReadLine();
            }
        }
    }
}
